import Login from './views/Login.vue'
import NotFound from './views/404.vue'
import Home from './views/Home.vue'
import Main from './views/Main.vue'
import Table from './views/nav1/Table.vue'
import Form from './views/nav1/Form.vue'
import user from './views/nav1/user.vue'
import Page4 from './views/nav2/Page4.vue'
import Page5 from './views/nav2/Page5.vue'
import Page6 from './views/nav3/Page6.vue'
import echarts from './views/charts/echarts.vue'
import NewsList from './views/news/NewsList'
import NewsStart from './views/news/NewsStart'
import ActivityList from './views/activity/ActivityList'
import ActivityStart from './views/activity/ActivityStart'
import CheckList from './views/check/CheckList'
import CultrueStart from './views/cultrue/CultrueStart'
import CultrueHistoryList from './views/cultrue/CultrueHistoryList'
import UserManager from './views/user/UserManager.vue'
import UserList from './views/user/userList.vue'
let routes = [

    //{ path: '/main', component: Main },
    {
        path: '/',
        component: Home,
        name: '新闻',
        iconCls: 'fa fa-bookmark',//图标样式class,
        meta:["school","company","admin"],
        children: [
            //{ path: '/main', component: Main, name: '新闻发布', hidden: true },
            {path: '/newsStart', component: NewsStart, name: '新闻发布' ,meta:["school","company","admin"],},
            {path: '/newsList', component: NewsList, name: '新闻列表', meta:["school","company","admin"],}
        ]
    },
    {
        path: '/',
        component: Home,
        name: '活动',
        iconCls: 'fa fa-group',
        meta:["school","company","admin","teacher"],
        children: [
            {path: '/activityStart', component: ActivityStart, name: '活动发布', meta:["school","company","admin","teacher"],},
            {path: '/activityList', component: ActivityList, name: '活动列表', meta:["school","company","admin","teacher"],}
        ]
    },
    {
        path: '/',
        component: Home,
        name: '审核',
        iconCls: 'fa fa-gavel',
        meta:["school","company","admin","teacher"],
        //leaf: true,//只有一个节点
        children: [
            {path: '/check', component: CheckList, name: '审核列表',meta:["school","company","admin","teacher"],}

        ]
    },
    {
        path: '/',
        component: Home,
        name: '用户',
        iconCls: 'fa fa-address-card',
        meta:["admin"],
        children: [
            {path: '/userlist', component: UserList, name: '用户管理',meta:["admin"],},
        ]
    },
    {
        path: '/',
        component: Home,
        name: '文化推荐',
        meta:["admin"],
        iconCls: 'fa fa-bar-chart',
        children: [
            {path: '/cultrueStart', component: CultrueStart, name: '分分钟文化人', meta:["admin"],},
            {path: '/cultrueH', component: CultrueHistoryList, name: '文化推荐列表', meta:["admin"],}
        ]
    },
    {
        path: '*',
        hidden: true,
        meta:["public"],
        redirect: {path: '/404'}
    },
    {
        path: '/login',
        component: Login,
        name: '',
        meta:["public"],
        hidden: true
    },
    {
        path: '/404',
        component: NotFound,
        name: '',
        meta:["public"],
        hidden: true
    },
];

export default routes;